<?php

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateTopRecordTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('set_top_record', function (Blueprint $table) {
            $table->increments('id');
            $table->integer('position_id')->default(0)->comment('职位id');
            $table->integer('hours')->default(0)->comment('置顶小时数');
            $table->integer('num')->default(0)->comment('使用的积分或rmb,1积分=1元');
            $table->timestamp('start_time')->nullable()->comment('置顶开始时间');
            $table->timestamp('end_time')->nullable()->comment('置顶结束时间');
            $table->string('type')->nullable()->comment('付款方式');
            $table->string('order_num')->nullable()->comment('订单号');
            $table->integer('status')->defulat(0)->comment('状态0:过期 1：置顶中');
            $table->softDeletes();
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::drop('user_info');
    }
}
